package xyz.msj.hrm.feign.client;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import xyz.msj.hrm.feign.fallback.MQFeignClientFackBallFactory;
import xyz.msj.hrm.util.AjaxResult;
import xyz.msj.hrm.vo.SendEmailVO;
import xyz.msj.hrm.vo.SendSMSVO;
import xyz.msj.hrm.vo.SendSystemMessageVO;

/**
 * feign接口
 */
@FeignClient(value = "mq-server", fallbackFactory = MQFeignClientFackBallFactory.class )
public interface MQFeignClient {
    /**
     * 发送短信
     * @return
     */
    @PostMapping("send/sendSMS")
    AjaxResult sendSMS(@RequestBody SendSMSVO vo);
    /**
     * 发送邮件
     * @return
     */
    @PostMapping("send/sendEmail")
    AjaxResult sendEmail(@RequestBody SendEmailVO vo);
    /**
     * 发送系统消息
     * @return
     */
    @PostMapping("send/sendSystemMessage")
    AjaxResult sendSystemMessage(@RequestBody SendSystemMessageVO vo);

}